import Home from '@/views/Home'
import Search from '@/views/Search'
import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter) // VueRouter插件初始化

// 创建了一个路由对象
const router = new VueRouter({
    routes: [
        { name: 'home', path: '/home', component: Home },
        { name: 'search', path: '/search', component: Search }
    ]
})

export default router